staging/lustre/lnet: Properly mark userspace pointer of lnet_ping()
authorOleg Drokin <green@linuxhacker.ru>
Sun, 3 Jan 2016 17:05:41 +0000 (12:05 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 3 Feb 2016 22:27:25 +0000 (14:27 -0800)
This also happens to silence sparce warnings about different
address spaces.

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/lustre/lnet/lnet/api-ni.c

index 80b170ee5582047646d4230566bc3f0a20ee7dd7..d33fbdf99505ab56afd96464cd208cce82f092d8 100644 (file)
@@ -62,7 +62,7 @@ module_param(rnet_htable_size, int, 0444);
 MODULE_PARM_DESC(rnet_htable_size, "size of remote network hash table");
 
 static int lnet_ping(lnet_process_id_t id, int timeout_ms,
-                    lnet_process_id_t *ids, int n_ids);
+                    lnet_process_id_t __user *ids, int n_ids);
 
 static char *
 lnet_get_routes(void)
@@ -1376,7 +1376,7 @@ LNetCtl(unsigned int cmd, void *arg)
                id.nid = data->ioc_nid;
                id.pid = data->ioc_u32[0];
                rc = lnet_ping(id, data->ioc_u32[1], /* timeout */
-                              (lnet_process_id_t *)data->ioc_pbuf1,
+                              data->ioc_pbuf1,
                               data->ioc_plen1/sizeof(lnet_process_id_t));
                if (rc < 0)
                        return rc;
@@ -1646,7 +1646,7 @@ lnet_ping_target_fini(void)
 }
 
 static int lnet_ping(lnet_process_id_t id, int timeout_ms,
-                    lnet_process_id_t *ids, int n_ids)
+                    lnet_process_id_t __user *ids, int n_ids)
 {
        lnet_handle_eq_t eqh;
        lnet_handle_md_t mdh;