4.9-stable review patch.  If anyone has any objections, please let me know.

------------------

From: Oleg Drokin <[email protected]>

commit dc7ffefdcc28a45214aa707fdc3df6a5e611ba09 upstream.

This is unbreaking another of those "stealth" janitor
patches that got in and subtly broke some things.

sv_cpt_data is a pointer to pointer, so need to
dereference it twice to allocate the correct structure size.

Fixes: 9899cb68c6c2 ("Staging: lustre: rpc: Use sizeof type *pointer instead of 
sizeof type.")
CC: Sandhya Bankar <[email protected]>
Signed-off-by: Oleg Drokin <[email protected]>
Reviewed-by: James Simmons <[email protected]>
Reviewed-by: Doug Oucharek <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>

---
 drivers/staging/lustre/lnet/selftest/rpc.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/drivers/staging/lustre/lnet/selftest/rpc.c
+++ b/drivers/staging/lustre/lnet/selftest/rpc.c
@@ -252,7 +252,7 @@ srpc_service_init(struct srpc_service *s
        svc->sv_shuttingdown = 0;
 
        svc->sv_cpt_data = cfs_percpt_alloc(lnet_cpt_table(),
-                                           sizeof(*svc->sv_cpt_data));
+                                           sizeof(**svc->sv_cpt_data));
        if (!svc->sv_cpt_data)
                return -ENOMEM;
 


Reply via email to