Re: [PATCH] lib: test_rhashtable: fix for large entry counts

2017-07-24 Thread David Miller
From: Phil Sutter Date: Fri, 21 Jul 2017 16:51:31 +0200 > During concurrent access testing, threadfunc() concatenated thread ID > and object index to create a unique key like so: > > | tdata->objs[i].value = (tdata->id << 16) | i; > > This breaks if a user passes an entries parameter of 64k or

Re: [PATCH] lib: test_rhashtable: fix for large entry counts

2017-07-23 Thread Herbert Xu
On Fri, Jul 21, 2017 at 04:51:31PM +0200, Phil Sutter wrote: > During concurrent access testing, threadfunc() concatenated thread ID > and object index to create a unique key like so: > > | tdata->objs[i].value = (tdata->id << 16) | i; > > This breaks if a user passes an entries parameter of 64k

[PATCH] lib: test_rhashtable: fix for large entry counts

2017-07-21 Thread Phil Sutter
During concurrent access testing, threadfunc() concatenated thread ID and object index to create a unique key like so: | tdata->objs[i].value = (tdata->id << 16) | i; This breaks if a user passes an entries parameter of 64k or higher, since 'i' might use more than 16 bits then. Effectively, this