Message ID | 20180620103555.1342-4-berrange@redhat.com |
---|---|
State | New |
Headers | show
Return-Path: <qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=nongnu.org (client-ip=2001:4830:134:3::11; helo=lists.gnu.org; envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org; receiver=<UNKNOWN>) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=redhat.com Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 419hD60lsXz9rxs for <incoming@patchwork.ozlabs.org>; Wed, 20 Jun 2018 20:39:50 +1000 (AEST) Received: from localhost ([::1]:48058 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from <qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org>) id 1fVaWh-0003YP-LG for incoming@patchwork.ozlabs.org; Wed, 20 Jun 2018 06:39:47 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:40005) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from <berrange@redhat.com>) id 1fVaT9-0001m0-3j for qemu-devel@nongnu.org; Wed, 20 Jun 2018 06:36:07 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from <berrange@redhat.com>) id 1fVaT8-0007r3-Bw for qemu-devel@nongnu.org; Wed, 20 Jun 2018 06:36:07 -0400 Received: from mx3-rdu2.redhat.com ([66.187.233.73]:57552 helo=mx1.redhat.com) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from <berrange@redhat.com>) id 1fVaT8-0007qq-7x for qemu-devel@nongnu.org; Wed, 20 Jun 2018 06:36:06 -0400 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id C323987AAB; Wed, 20 Jun 2018 10:36:05 +0000 (UTC) Received: from t460.redhat.com (unknown [10.33.36.101]) by smtp.corp.redhat.com (Postfix) with ESMTP id 4B8A22026D6B; Wed, 20 Jun 2018 10:36:04 +0000 (UTC) From: =?utf-8?q?Daniel_P=2E_Berrang=C3=A9?= <berrange@redhat.com> To: qemu-devel@nongnu.org Date: Wed, 20 Jun 2018 11:35:47 +0100 Message-Id: <20180620103555.1342-4-berrange@redhat.com> In-Reply-To: <20180620103555.1342-1-berrange@redhat.com> References: <20180620103555.1342-1-berrange@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Scanned-By: MIMEDefang 2.78 on 10.11.54.4 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.1]); Wed, 20 Jun 2018 10:36:05 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.1]); Wed, 20 Jun 2018 10:36:05 +0000 (UTC) for IP:'10.11.54.4' DOMAIN:'int-mx04.intmail.prod.int.rdu2.redhat.com' HELO:'smtp.corp.redhat.com' FROM:'berrange@redhat.com' RCPT:'' Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 66.187.233.73 Subject: [Qemu-devel] [PATCH v3 03/11] hw/usb: don't set IN_ISDIR for inotify watch in MTP driver X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: <qemu-devel.nongnu.org> List-Unsubscribe: <https://lists.nongnu.org/mailman/options/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=unsubscribe> List-Archive: <http://lists.nongnu.org/archive/html/qemu-devel/> List-Post: <mailto:qemu-devel@nongnu.org> List-Help: <mailto:qemu-devel-request@nongnu.org?subject=help> List-Subscribe: <https://lists.nongnu.org/mailman/listinfo/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=subscribe> Cc: "Dr. David Alan Gilbert" <dgilbert@redhat.com>, Markus Armbruster <armbru@redhat.com>, Gerd Hoffmann <kraxel@redhat.com>, =?utf-8?q?And?= =?utf-8?q?reas_F=C3=A4rber?= <afaerber@suse.de> Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" <qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org> |
Series |
Add a standard authorization framework
|
expand
|
diff --git a/hw/usb/dev-mtp.c b/hw/usb/dev-mtp.c index 1ded7ac9a3..80f88e40fa 100644 --- a/hw/usb/dev-mtp.c +++ b/hw/usb/dev-mtp.c @@ -638,8 +638,7 @@ static void usb_mtp_inotify_cleanup(MTPState *s) static int usb_mtp_add_watch(int inotifyfd, char *path) { - uint32_t mask = IN_CREATE | IN_DELETE | IN_MODIFY | - IN_ISDIR; + uint32_t mask = IN_CREATE | IN_DELETE | IN_MODIFY; return inotify_add_watch(inotifyfd, path, mask); }
IN_ISDIR is not a bit that one can request when registering a watch with inotify_add_watch. Rather it is a bit that is set automatically when reading events from the kernel. Signed-off-by: Daniel P. Berrangé <berrange@redhat.com> --- hw/usb/dev-mtp.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)