[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH] gnttab: maptrack handle shortage is not IOMMU related


  • To: "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Jan Beulich <jbeulich@xxxxxxxx>
  • Date: Mon, 30 Aug 2021 16:27:15 +0200
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=yC+0CivQwFaVmzF0Rucm+NRWZ6WjJbQt2jxwUZYJH8Y=; b=e2gBS51SVY2XbVwht8PyhDfAp5ZvjA2r4jIYAF1QwgP8tIOKj27bj/5OyCJFZrNYDo8Zx1QZSpxtBy9VXNbKn8BW8ZC0To71mMxr2I7prA8s4lC5owB7RNlS2nZLBjH7p1xZwf8skMEPKbTb+L3ytZ2ftG6qJ7ho1nK6lhrJU40kwdIu3uyIKbuOX5BoxYyirnuEPwY7AV1k2RyjcCbZ5hPCts+MC6Q4Z0LXjBGZLxp5IakbRovDp0aGNBFkF9QrnXGXHhrxlIuVOSHC2Dt2nB8B+MikqZ09KKOW4VEZ2+OvvokEiHEqSmw+pEFGzRBVL6rVs8kyOR9AzkZhXk6DJQ==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=je7tNffUUyve0ecoeTBjrQRFeTYQRov/cPJq92j0BNbk5R3aUo20sGOa5DJqzjKp5hhj6s9yFXvjHD1WnHul/MpO1/pLTpju2HTnoto2NUU5dyFnYlEfgVUrHSqAGaPAq9WSwtXpLNNkDhqe3SHWtsRtRFu7brsK7bzZ0Z3AWLI4CUmFhL309bAz3cNwkxo4j2aq0A9m7/HxMmcTotiW+WhCbGKlVi/qX+0mQolbCdC5/WWyIoVs8ob2G6vAR/6cmKdYfuy1KxvN2Kmpy7/Ys7yiz+FYFS8lt1hPeza/AJddwKyrlcCVTsj5C4ABZBuCGrB/o3iukQN/TdPbNY6Ebw==
  • Authentication-results: xen.org; dkim=none (message not signed) header.d=none;xen.org; dmarc=none action=none header.from=suse.com;
  • Cc: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, George Dunlap <george.dunlap@xxxxxxxxxx>, Ian Jackson <iwj@xxxxxxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>
  • Delivery-date: Mon, 30 Aug 2021 14:27:26 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

Both comment and message string associated with GNTST_no_device_space
suggest a connection to the IOMMU. A lack of maptrack handles has
nothing to do with that; it's unclear to me why commit 6213b696ba65
("Grant-table interface redone") introduced it this way. Introduce a
new error indicator.

Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>
---
Or should this be a more specific one, e.g. GNTST_no_mt_handle? If not,
I would intend to also use GNTST_no_space for -ENOMEM like situations.

--- a/xen/common/grant_table.c
+++ b/xen/common/grant_table.c
@@ -1027,7 +1027,7 @@ map_grant_ref(
     {
         rcu_unlock_domain(rd);
         gdprintk(XENLOG_INFO, "Failed to obtain maptrack handle\n");
-        op->status = GNTST_no_device_space;
+        op->status = GNTST_no_space;
         return;
     }
 
--- a/xen/include/public/grant_table.h
+++ b/xen/include/public/grant_table.h
@@ -652,6 +652,7 @@ DEFINE_XEN_GUEST_HANDLE(gnttab_cache_flu
 #define GNTST_bad_copy_arg    (-10) /* copy arguments cross page boundary.   */
 #define GNTST_address_too_big (-11) /* transfer page address too large.      */
 #define GNTST_eagain          (-12) /* Operation not done; try again.        */
+#define GNTST_no_space        (-13) /* Out of space (handles etc).           */
 /* ` } */
 
 #define GNTTABOP_error_msgs {                   \
@@ -667,7 +668,8 @@ DEFINE_XEN_GUEST_HANDLE(gnttab_cache_flu
     "bad page",                                 \
     "copy arguments cross page boundary",       \
     "page address size too large",              \
-    "operation not done; try again"             \
+    "operation not done; try again",            \
+    "out of space",                             \
 }
 
 #endif /* __XEN_PUBLIC_GRANT_TABLE_H__ */




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.