Prechádzať zdrojové kódy

xenbus: maximum buffer size is XENSTORE_PAYLOAD_MAX

Use this now that it is defined even though it happens to be == PAGE_SIZE.

The code which takes requests from userspace already validates against the size
of this buffer so no further checks are required to ensure that userspace
requests comply with the protocol in this respect.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Cc: Haogang Chen <haogangchen@gmail.com>
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Ian Campbell 14 rokov pred
rodič
commit
50bf73796e
1 zmenil súbory, kde vykonal 1 pridanie a 1 odobranie
  1. 1 1
      drivers/xen/xenbus/xenbus_dev_frontend.c

+ 1 - 1
drivers/xen/xenbus/xenbus_dev_frontend.c

@@ -105,7 +105,7 @@ struct xenbus_file_priv {
 	unsigned int len;
 	unsigned int len;
 	union {
 	union {
 		struct xsd_sockmsg msg;
 		struct xsd_sockmsg msg;
-		char buffer[PAGE_SIZE];
+		char buffer[XENSTORE_PAYLOAD_MAX];
 	} u;
 	} u;
 
 
 	/* Response queue. */
 	/* Response queue. */