From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752631AbbCIHRD (ORCPT ); Mon, 9 Mar 2015 03:17:03 -0400 Received: from ozlabs.org ([103.22.144.67]:48874 "EHLO ozlabs.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751097AbbCIHRA (ORCPT ); Mon, 9 Mar 2015 03:17:00 -0400 From: Rusty Russell To: "Michael S. Tsirkin" Cc: linux-kernel@vger.kernel.org, virtualization@lists.linux-foundation.org Subject: Re: [PATCH] virtio_balloon: set DRIVER_OK before using device In-Reply-To: <20150305083905.GA11474@redhat.com> References: <1425474779-29412-1-git-send-email-mst@redhat.com> <877fuwjgqw.fsf@rustcorp.com.au> <20150305083905.GA11474@redhat.com> User-Agent: Notmuch/0.17 (http://notmuchmail.org) Emacs/24.3.1 (x86_64-pc-linux-gnu) Date: Mon, 09 Mar 2015 17:33:35 +1030 Message-ID: <87385ey7nc.fsf@rustcorp.com.au> MIME-Version: 1.0 Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org "Michael S. Tsirkin" writes: > On Thu, Mar 05, 2015 at 01:24:47PM +1030, Rusty Russell wrote: >> "Michael S. Tsirkin" writes: >> > virtio spec requires that all drivers set DRIVER_OK >> > before using devices. While balloon isn't yet >> > included in the virtio 1 spec, previous spec versions >> > also required this. >> > >> > virtio balloon might violate this rule: probe calls >> > kthread_run before setting DRIVER_OK, which might run >> > immediately and cause balloon to inflate/deflate. >> > >> > To fix, call virtio_device_ready before running the kthread. >> > >> > Signed-off-by: Michael S. Tsirkin >> >> Replied, CC'd stable. > > Did you mean applied? I stand erected. Franks, Rusty.