be an ABI breakage?
Signed-off-by: NeilBrown
---
fs/cifs/file.c |2 +-
fs/locks.c | 40 ---
include/linux/fs.h |5 +++--
include/trace/events/filelock.h | 16
4 files changed, 33
st is removed, all blocked requests are woken.
- When deadlock-detection looks for the lock which blocks a
given request, we follow the chain of ->fl_blocker all
the way to the top.
Signed-off-by: NeilBrown
---
fs/locks.c | 58 --
convert some
return (foo);
to
return foo;
Signed-off-by: NeilBrown
---
fs/locks.c | 24
1 file changed, 12 insertions(+), 12 deletions(-)
diff --git a/fs/locks.c b/fs/locks.c
index b4812da2a374..aaa55925c788 100644
--- a/fs/locks.c
+++ b/fs/locks.c
@@ -793,47
change we lose __GFP_NOWARN and __GFP_NORETRY.
I doubt the NORETRY is particularly important as this is if it
isn't GFP_KERNEL, then it is GFP_ATOMIC which doesn't retry anyway.
However I cannot see why this patch won't result in warnings when the
kzalloc() fails.
What am I missing?
Thank
On Wed, Aug 08 2018, Frank Filz wrote:
>> On Wed, Aug 08, 2018 at 03:54:45PM -0400, J. Bruce Fields wrote:
>> > On Wed, Aug 08, 2018 at 11:51:07AM +1000, NeilBrown wrote:
>> > > If you have a many-core machine, and have many threads all wanting
>> > > to bri
On Wed, Aug 08 2018, J. Bruce Fields wrote:
> On Wed, Aug 08, 2018 at 04:09:12PM -0400, J. Bruce Fields wrote:
>> On Wed, Aug 08, 2018 at 03:54:45PM -0400, J. Bruce Fields wrote:
>> > On Wed, Aug 08, 2018 at 11:51:07AM +1000, NeilBrown wrote:
>> > > If you have a ma
On Wed, Aug 08 2018, J. Bruce Fields wrote:
> On Wed, Aug 08, 2018 at 12:47:22PM -0400, Jeff Layton wrote:
>> On Wed, 2018-08-08 at 11:51 +1000, NeilBrown wrote:
>> > If you have a many-core machine, and have many threads all wanting to
>> > briefly lock a give fil
e lock
acquisitions per second drops from 1.8 million to 1.4 million with
this patch. For 100 processes, this patch still provides 1.4 million
while without this patch there are about 700,000.
NeilBrown
---
NeilBrown (5):
fs/locks: rename some lists and pointers.
fs/locks: allow a lock r
be an ABI breakage?
Signed-off-by: NeilBrown
---
fs/cifs/file.c |2 +-
fs/locks.c | 40 ---
include/linux/fs.h |5 +++--
include/trace/events/filelock.h | 16
4 files changed, 33
st is removed, all blocked requests are woken.
- When deadlock-detection looks for the lock which blocks a
given request, we follow the chain of ->fl_blocker all
the way to the top.
Signed-off-by: NeilBrown
---
fs/locks.c | 58 --
. The rest of the herd can stay asleep.
Reported-and-tested-by: Martin Wilck
Signed-off-by: NeilBrown
---
fs/locks.c | 69 +++-
1 file changed, 63 insertions(+), 6 deletions(-)
diff --git a/fs/locks.c b/fs/locks.c
index fc64016d01ee
This functionality will be useful in the next patch, so
split it out from __locks_wake_up_blocks().
Signed-off-by: NeilBrown
---
fs/locks.c | 15 ++-
1 file changed, 10 insertions(+), 5 deletions(-)
diff --git a/fs/locks.c b/fs/locks.c
index d06658b2dc7a..fc64016d01ee 100644
o current code which only tests the
truth value of these functions will still work the same way.
And convert some
return (foo);
to
return foo;
Signed-off-by: NeilBrown
---
fs/locks.c | 64 ++--
1 file changed, 49 insertions(+), 15 de
just a
different owner.
So this enhancement should work equally for posix, flock, ofd and even
leases.
Thanks,
NeilBrown
>
> Frank
signature.asc
Description: PGP signature
in the one process - OK.
Tasks 2 and 3 are threads in two other processes.
So 2 and 3 conflict with either 1 or 4 equally - why should task 3 be
woken?
I suspect you got the numbers bit mixed up, but in any case, the
"conflict()" function that is passed around takes ownership i
On Thu, Aug 09 2018, J. Bruce Fields wrote:
> On Thu, Aug 09, 2018 at 12:04:41PM +1000, NeilBrown wrote:
>> When we find an existing lock which conflicts with a request,
>> and the request wants to wait, we currently add the request
>> to a list. When the lock is removed, th
On Thu, Aug 09 2018, Jeff Layton wrote:
> On Thu, 2018-08-09 at 12:04 +1000, NeilBrown wrote:
>> When we find an existing lock which conflicts with a request,
>> and the request wants to wait, we currently add the request
>> to a list. When the lock is removed, the whole l
On Thu, Aug 09 2018, J. Bruce Fields wrote:
> On Thu, Aug 09, 2018 at 12:04:41PM +1000, NeilBrown wrote:
>> In a future patch we will need to differentiate between conflicts that
>> are "transitive" and those that aren't.
>> A "transitive"
oo complex, it would
certainly be an option. I think the tree approach should result in less
total CPU usage..
Thanks for the thought - taking this simple approach really hadn't
occurred to me. :-(
NeilBrown
signature.asc
Description: PGP signature
On Thu, Aug 09 2018, J. Bruce Fields wrote:
> On Fri, Aug 10, 2018 at 08:12:43AM +1000, NeilBrown wrote:
>> On Thu, Aug 09 2018, J. Bruce Fields wrote:
>>
>> > I think there's also a problem with multiple tasks sharing the same
>> > lock owner.
>> >
On Thu, Aug 09 2018, J. Bruce Fields wrote:
> On Fri, Aug 10, 2018 at 11:50:58AM +1000, NeilBrown wrote:
>> You're good at this game!
>
> Everybody's got to have a hobby, mine is pathological posix locking
> cases
>
>> So, because a locker with the s
This functionality will be useful in future patches, so
split it out from locks_wake_up_blocks().
Signed-off-by: NeilBrown
---
fs/locks.c | 27 ---
1 file changed, 16 insertions(+), 11 deletions(-)
diff --git a/fs/locks.c b/fs/locks.c
index 322491e70e41..de0b9276f23d
to report fl_blocker instead
of fl_next.
Signed-off-by: NeilBrown
---
fs/cifs/file.c |2 +-
fs/locks.c | 40 ---
include/linux/fs.h |7 +--
include/trace/events/filelock.h | 16 ---
a particular test on 72 cores, the lock
acquisitions per second drops from 1.8 million to 1.4 million with
this patch. For 100 processes, this patch still provides 1.4 million
while without this patch there are about 700,000.
NeilBrown
---
NeilBrown (5):
fs/locks: rename some lists and
st is requeued or discarded, all blocked requests are
woken.
- When deadlock-detection looks for the lock which blocks a
given request, we follow the chain of ->fl_blocker all
the way to the top.
Signed-off-by: NeilBrown
---
fs/locks.c | 43 +++
Wilck
Signed-off-by: NeilBrown
---
fs/locks.c | 29 +++--
1 file changed, 23 insertions(+), 6 deletions(-)
diff --git a/fs/locks.c b/fs/locks.c
index c7a372cebff1..af250afceff4 100644
--- a/fs/locks.c
+++ b/fs/locks.c
@@ -727,11 +727,25 @@ static void locks_delete_block
convert some
return (foo);
to
return foo;
Signed-off-by: NeilBrown
---
fs/locks.c | 27 +++
1 file changed, 15 insertions(+), 12 deletions(-)
diff --git a/fs/locks.c b/fs/locks.c
index 9439eebd4eb9..c7a372cebff1 100644
--- a/fs/locks.c
+++ b/fs/locks.c
@@ -803,47
On Thu, Aug 16 2018, NeilBrown wrote:
> On Wed, Aug 15 2018, Jeff Layton wrote:
>
>> On Wed, 2018-08-15 at 14:28 +0200, Krzysztof Kozlowski wrote:
>>> Hi,
>>>
>>> Bisect pointed commit ce3147990450a68b3f549088b30f087742a08b5d
>>> ("fs/lock
On Tue, Aug 21 2018, Jeff Layton wrote:
> On Tue, 2018-08-21 at 15:11 +1000, NeilBrown wrote:
>> On Thu, Aug 16 2018, NeilBrown wrote:
>>
>> > On Wed, Aug 15 2018, Jeff Layton wrote:
>> >
>> > > On Wed, 2018-08-15 at 14:28 +0200, Krzysztof Kozlowski
->s_type->i_mutex_key#9 --> &mm->mmap_sem --> ashmem_mutex
>>
>> Possible unsafe locking scenario:
>>
>>CPU0CPU1
>>
>> lock(ashmem_mutex);
>>
On Wed, Aug 22 2018, NeilBrown wrote:
>
> Oh dear.
> nfs4_alloc_lockdata contains:
> memcpy(&p->fl, fl, sizeof(p->fl));
>
> so any list_heads that are valid in fl will be invalid in p->fl.
>
> Maybe I should initialize the relevant list_heads at the
On Fri, Jul 27 2018, Nishad Kamdar wrote:
> Replace explicit shifting with BIT macro in board.h.
> Issue found by checkpatch.
>
> Signed-off-by: Nishad Kamdar
Reviewed-by: NeilBrown
Thanks,
NeilBrown
> ---
> drivers/staging/mt7621-mmc/board.h | 8
> 1 file
On Fri, Jul 27 2018, Paul E. McKenney wrote:
> On Thu, Jul 26, 2018 at 08:18:15PM -0700, Paul E. McKenney wrote:
>> On Fri, Jul 27, 2018 at 11:04:37AM +1000, NeilBrown wrote:
>> > On Wed, Jul 25 2018, Paul E. McKenney wrote:
>> > >>
>> > &
On Mon, Jul 23 2018, Brian Norris wrote:
> Hi,
>
> I'm a little late to this thread, but I recently noticed (and
> complained about) commit: 59b356ffd0b0 ("mtd: m25p80: restore the
> status of SPI flash when exiting").
>
> On Mon, Apr 9, 2018 at 6:05 PM, Neil
On Mon, Jul 23 2018, Brian Norris wrote:
> Hi Neil,
>
> On Mon, Jul 23, 2018 at 2:45 PM, NeilBrown wrote:
>> On Mon, Jul 23 2018, Brian Norris wrote:
>>> On Mon, Apr 9, 2018 at 6:05 PM, NeilBrown wrote:
>>>> On Mon, Apr 09 2018, Marek Vasut wrote:
>>&
that one has to
> admit that their board design is broken before it will even do
> anything. Proposal: "linux,badly-designed-flash-reset".
>
> But, I'd prefer just (partially?) reverting this, and let the authors
> submit something that works. We're not obligated to keep bad hacks in
> the kernel.
>
> Brian
One possibility that occurred to me when I was exploring this issue is
to revert to 3-byte mode whenever 4-byte was not actively in use.
So any access beyond 16Meg is:
switch-to-4-byte ; perform IO ; switch to 3-byte
or similar. On my hardware it would be more efficient to
use the 4-byte opcode to perform the IO, then reset the cached
4th address byte that the NOR chip transparently remembered.
This adds a little overhead, but should be fairly robust.
It doesn't help if something goes terribly wrong while IO is happening,
but I don't think any other software solution does either.
How would you see that approach?
Thanks,
NeilBrown
signature.asc
Description: PGP signature
On Tue, Jul 24 2018, Boris Brezillon wrote:
> On Tue, 24 Jul 2018 08:46:33 +1000
> NeilBrown wrote:
>
>> On Mon, Jul 23 2018, Brian Norris wrote:
>>
>> > Hi Boris,
>> >
>> > On Mon, Jul 23, 2018 at 1:10 PM, Boris Brezillon
>> > wrot
On Tue, Jul 24 2018, Brian Norris wrote:
> Hi,
>
> On Tue, Jul 24, 2018 at 11:51:49AM +1000, NeilBrown wrote:
>> On Tue, Jul 24 2018, Boris Brezillon wrote:
>> > On Tue, 24 Jul 2018 08:46:33 +1000
>> > NeilBrown wrote:
>> >> One possibility that occu
On Tue, Jul 24 2018, Paul E. McKenney wrote:
> On Tue, Jul 24, 2018 at 07:52:03AM +1000, NeilBrown wrote:
>> On Mon, Jul 23 2018, Paul E. McKenney wrote:
>>
>> > On Mon, Jul 23, 2018 at 09:13:43AM +1000, NeilBrown wrote:
>> >> On Sun, Jul 22 2018, Paul E.
On Wed, Jul 11 2018, David Miller wrote:
> From: David Miller
> Date: Wed, 11 Jul 2018 22:46:58 -0700 (PDT)
>
>> From: NeilBrown
>> Date: Fri, 06 Jul 2018 17:08:35 +1000
>>
>>>
>>> Some users of rhashtable might need to change the key
>>&g
utual exclusion which anything that might change the key, such as
successfully taking a new reference.
Signed-off-by: NeilBrown
---
include/linux/rhashtable.h | 35 +++
lib/rhashtable.c | 8 +---
2 files changed, 28 insertions(+), 15 deletions(-)
diff --
On Tue, Jul 10 2018, David Miller wrote:
> From: NeilBrown
> Date: Fri, 06 Jul 2018 17:11:32 +1000
>
>> rhashtable_walk_last_seen() returns the object returned by
>> the previous rhashtable_walk_next(), providing it is still in the
>> table (or was during this grace
On Mon, Jul 16 2018, Herbert Xu wrote:
> On Mon, Jul 16, 2018 at 09:57:11AM +1000, NeilBrown wrote:
>>
>> Some users of rhashtable might need to change the key
>> of an object and move it to a different location in the table.
>> Other users might wan
t inode *inode,
> *p++ = cpu_to_be32(convert_to_wallclock(exp->cd->flush_time));
> *p++ = 0;
> } else if (IS_I_VERSION(inode)) {
> - p = xdr_encode_hyper(p, inode->i_version);
> + p = xdr_encode_hyper(p, nfsd4_cha
There are now no users. workqueues are doing the job
that this used to do.
Signed-off-by: NeilBrown
---
.../staging/lustre/include/linux/libcfs/libcfs.h |1
.../lustre/include/linux/libcfs/libcfs_workitem.h | 104
drivers/staging/lustre/lnet/libcfs/Makefile|2
This is a resend of the last two patches of my "remove workitem code",
which resolve a merge conflict and add and 'Ack-by' from Tejun.
The first two patches have already been merged.
Thanks,
NeilBrown
Original intro:
Lustre has a "workitem" subsystem with much the s
workqueue API, that isn't currently
exported. lustre needs it to allow workqueue thread to be limited
to a subset of CPUs.
Acked-by: Tejun Heo (for export of apply_workqueue_attrs)
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lnet/selftest/framework.c | 10 +---
drivers/staging/l
ough the NFS tree when the rest of the patches are ready.
Thanks,
NeilBrown
---
NeilBrown (4):
cred: add cred_fscmp() for comparing creds.
cred: add get_cred_rcu()
cred: export get_task_cred().
cred: allow get_cred() and put_cred() to be given NULL.
include/linux/
er to more consistent
use of 'struct cred' we need a comparison function.
This patch adds that function.
Signed-off-by: NeilBrown
---
include/linux/cred.h |1 +
kernel/cred.c| 55 ++
2 files changed, 56 insertions(+)
diff -
There is no reason that modules should not be able
to use this, and NFS will need it when converted to
use 'struct cred'.
Signed-off-by: NeilBrown
---
kernel/cred.c |1 +
1 file changed, 1 insertion(+)
diff --git a/kernel/cred.c b/kernel/cred.c
index f11aa4e0d2b9..3e43bde1fd3c 10
It is common practice of helps like this so silently,
accept a NULL pointer.
get_rpccred() and put_rpccred() used by NFS act this way
and using the same interface will ease the conversion
for NFS, and simplify the resulting code.
Signed-off-by: NeilBrown
---
include/linux/cred.h | 14
use it in
get_task_cred().
Signed-off-by: NeilBrown
---
include/linux/cred.h | 11 +++
kernel/cred.c|2 +-
2 files changed, 12 insertions(+), 1 deletion(-)
diff --git a/include/linux/cred.h b/include/linux/cred.h
index 6dd51e503f23..69ed76f7d49f 100644
--- a/include/linux/cr
ing a cpumask_var and copying
into it, rather than sharing the mask.
Reported-by: kbuild test robot
Fixes: 6106c0f82481 ("staging: lustre: lnet: convert selftest to use
workqueues")
Signed-off-by: NeilBrown ctb_parts[i].cpt_cpumask;
- #else
- cpumask_copy(
, in case including the
kernel-doc in credentials.rst like this was the wrong direction.
Thanks,
NeilBrown
--8<-----
From: NeilBrown
Subject: [PATCH] Documentation: include kernel-doc in credentials.rst
- kernel-doc from include/linux/cred.h, k
e (as I
understand it) doesn't seem to agree with comments/debug message, or
just generally looks odd.
Thanks,
NeilBrown
---
NeilBrown (19):
sched/wait: add wait_event_idle() functions.
staging: lustre: discard SVC_SIGNAL and related functions
staging: lustre: replace si
This flag is never set, so remove checks and remove
the flag.
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lustre/include/lustre_net.h |6 --
drivers/staging/lustre/lustre/ptlrpc/sec_gc.c |4 +---
2 files changed, 1 insertion(+), 9 deletions(-)
diff --git a/drivers
needing to block signals.
In one case, wait_event_idle_exclusive() is needed.
Also remove all l_wait_condition*() macros which were short-cuts
for setting lwi to {0}.
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lustre/include/lustre_lib.h | 19
drivers/staging/lustre/lustre
return -ERESTARTSYS.
l_wait_event_{abortable_,}exclusive follow the Linux pattern.
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lustre/include/lustre_lib.h | 24
drivers/staging/lustre/lustre/ldlm/ldlm_resource.c | 12 +-
drivers/staging/lustre/lustre
()
wait_event_idle_exclusive_timeout()
This set was chosen because lustre needs them before
it can discard its own l_wait_event() macro.
Acked-by: Peter Zijlstra (Intel)
Signed-off-by: NeilBrown
---
include/linux/wait.h | 114 ++
1 file changed, 114 insertions(+)
diff
used.
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lustre/ldlm/ldlm_lock.c | 10 ++--
drivers/staging/lustre/lustre/ldlm/ldlm_pool.c | 12 +++---
drivers/staging/lustre/lustre/llite/statahead.c| 14 ---
drivers/staging/lustre/lustre/mdc/mdc_request.c
cfs_time_seconds() converts a number of seconds to the
matching number of jiffies.
The standard way to do this in Linux is "* HZ".
So discard cfs_time_seconds() and use "* HZ" instead.
Signed-off-by: NeilBrown
---
.../lustre/include/linux/libcfs/libcfs_debug.h |
he condition is true if it is signaled.
This doesn't quite agree with the comments and debug messages.
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lustre/ldlm/ldlm_request.c | 55 +++--
1 file changed, 18 insertions(+), 37 deletions(-)
diff --git a/drivers/stagin
Two places that LWI_TIMEOUT_INTERVAL() is used, the outcome is a
simple polling loop that polls every second for some event (with a
limit).
So write a simple loop to make this more apparent.
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lustre/llite/llite_lib.c | 11
function after the
wait_event, if -ERESTARTSYS was returned.
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lustre/ldlm/ldlm_flock.c | 30 +--
1 file changed, 7 insertions(+), 23 deletions(-)
diff --git a/drivers/staging/lustre/lustre/ldlm/ldlm_flock.c
b/drivers/staging
Rather an using l_wait_event(), use wait_event_idle_timeout()
with an explicit loop so it is easier to see what is happening.
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lustre/ptlrpc/service.c | 15 ---
1 file changed, 8 insertions(+), 7 deletions(-)
diff --git a/drivers
We can replace l_wait_event() with
wait_event_idle_timeout() here providing we call the
timeout function when wait_event_idle_timeout() returns zero.
As ptlrpc_expired_set() returns 1, the l_wait_event() aborts of the
first timeout.
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lustre
Replace l_wait_event with wait_event_idle_timeout() and call the
handler function explicitly. This makes it more clear
what is happening.
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lustre/ptlrpc/sec.c | 34
1 file changed, 24 insertions(+), 10 deletions
This is the last remaining use of l_wait_event().
It is the only use of LWI_TIMEOUT_INTR_ALL() which
has a meaning that timeouts can be interrupted.
Only interrupts by "fatal" signals are allowed, so
introduce l_wait_event_abortable_timeout() to
support this.
Signed-off-by:
replace l_wait_event() with wait_event_idle_timeout() and explicit
loop. This approach is easier to understand.
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lustre/ptlrpc/client.c | 14 +++---
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/drivers/staging/lustre
This use of l_wait_event() is a polling loop that re-checks
every second. Make this more obvious with a while loop
and wait_event_idle_timeout().
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lustre/ptlrpc/niobuf.c | 15 ---
1 file changed, 8 insertions(+), 7 deletions
laces "back_to_sleep()" is
used but using two explicit sleeps.
The code in ptlrpcd_add_req() looks odd - why not just have one
wait_event_idle()? However I believe this is a faithful
transformation of the existing code.
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lust
-off-by: NeilBrown
---
drivers/staging/lustre/lustre/ptlrpc/client.c |3 ++-
drivers/staging/lustre/lustre/ptlrpc/import.c | 21 -
2 files changed, 10 insertions(+), 14 deletions(-)
diff --git a/drivers/staging/lustre/lustre/ptlrpc/client.c
b/drivers/staging/lustre/lustre
timeout setting.
The current code arrange for LIFO queuing of waiters,
but include/event.h doesn't support that yet.
Until it does, fall back on FIFO with
wait_event_idle_exclusive{,_timeout}().
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lustre/ptlrpc/service.c |
These macros are no longer used, so they can
be removed.
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lustre/include/lustre_lib.h | 249
1 file changed, 249 deletions(-)
diff --git a/drivers/staging/lustre/lustre/include/lustre_lib.h
b/drivers/staging/lustre
On Mon, Jan 08 2018, Greg Kroah-Hartman wrote:
> On Mon, Dec 18, 2017 at 11:46:30AM +1100, NeilBrown wrote:
>> All usages of the form
>> LIBCFS_ALLOC(variable, sizeof(variable))
>> or
>> LIBCFS_ALLOC(variable, sizeof(variable's-type))
>>
>> a
w.
Thanks,
NeilBrown
==
Lustre has some "convenience" macros for allocating and freeing
memory.
They:
- warn if called from interrupt context
- use kvmalloc
- assume GFP_NOFS (which kvmalloc doesn't support)
- print an error if the allocation fails
- initialize the memo
, use kvmalloc().
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lnet/lnet/router_proc.c | 34
1 file changed, 17 insertions(+), 17 deletions(-)
diff --git a/drivers/staging/lustre/lnet/lnet/router_proc.c
b/drivers/staging/lustre/lnet/lnet/router_proc.c
index 43038f9
locations that need changing.
As there are quite a lot, I've broken them up into several
ad-hoc sets to avoid review-fatigue.
Signed-off-by: NeilBrown
---
.../lustre/include/linux/libcfs/libcfs_string.h|4 ++--
.../staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c|
e which 99 bytes on the stack, instead of the 24 that would
have been allocated for 64-bit pointers.
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lnet/selftest/conctl.c | 180 -
1 file changed, 29 insertions(+), 151 deletions(-)
diff --git a/drivers/staging/lustre/lne
() has been called on it.
Signed-off-by: NeilBrown
---
.../lustre/include/linux/libcfs/libcfs_cpu.h |4 -
.../lustre/include/linux/libcfs/linux/linux-cpu.h |4 -
.../staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c|6 +
drivers/staging/lustre/lnet/libcfs/libcfs_cpu.c|2
None of these need to be GFP_NOFS, so use GFP_KERNEL explicitly
with kmalloc(), kvmalloc(), or kvmalloc_array().
Change matching LIBCFS_FREE() to kfree() or kvfree()
Signed-off-by: NeilBrown
---
.../lustre/lnet/libcfs/linux/linux-module.c|4 +-
drivers/staging/lustre/lnet/libcfs
None of these need GFP_NOFS so allocate directly.
Change matching LIBCFS_FREE() to kfree() or kvfree().
Signed-off-by: NeilBrown
---
.../staging/lustre/lnet/libcfs/linux/linux-cpu.c | 19 +++
drivers/staging/lustre/lnet/lnet/lib-eq.c |9 -
drivers
alloc option, or any of the other minor
benefits of LIBCFS_ALLOC().
Signed-off-by: NeilBrown
---
.../staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c| 39 ++--
.../staging/lustre/lnet/klnds/o2iblnd/o2iblnd_cb.c |4 +-
.../lustre/lnet/klnds/o2iblnd/o2iblnd_modparams.c |
The size of the data structure is primarily controlled
by the iovec size, which is limited to 256.
Entries in this vector are 12 bytes, so the whole
will always fit in a page.
So it is safe to use kmalloc (kvmalloc not needed).
So replace LIBCFS_ALLOC with kmalloc.
Signed-off-by: NeilBrown
This allocation is reasonably small.
As the function is called "*_locked", it might not be safe
to perform a GFP_KERNEL allocation, so be safe and
use GFP_NOFS.
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lnet/lnet/router.c |5 ++---
1 file changed, 2 insertions(+), 3
Just call kzalloc(GFP_ATOMIC) directly.
We don't need the warning on failure.
Signed-off-by: NeilBrown
---
.../lustre/lustre/obdclass/lprocfs_status.c|7 +++
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/staging/lustre/lustre/obdclass/lprocfs_status
(..))
in the one case that lnet_cpt_table() isn't used.
When LIBCFS_CPT_ALLOC() is replaced, the matching LIBCFS_FREE()
is also replaced, with with kfree() or kvfree() as appropriate.
Signed-off-by: NeilBrown
---
.../lustre/include/linux/libcfs/libcfs_private.h | 19
.../staging/lustre
These are not called from filesystem context, so use
GFP_KERNEL, not LIBCFS_ALLOC().
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lnet/selftest/console.c | 57 +---
drivers/staging/lustre/lnet/selftest/framework.c |4 +
drivers/staging/lustre/lnet/selftest
this allocation is called from several places, but all are
during initialization, so GFP_NOFS is not needed.
So use kvmalloc and GFP_KERNEL.
Signed-off-by: NeilBrown
---
drivers/staging/lustre/lnet/libcfs/libcfs_mem.c |6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a
LIBCFS_ALLOC
LIBCFS_ALLOC_ATOMIC
LIBCFS_ALLOC_POST
LIBCFS_CPT_ALLOC
LIBCFS_FREE
are no longer used, and so are removed.
Signed-off-by: NeilBrown
---
.../lustre/include/linux/libcfs/libcfs_private.h | 51
1 file changed, 51 deletions(-)
diff --git a/drivers/staging
On Mon, Jan 08 2018, Greg Kroah-Hartman wrote:
> On Mon, Dec 18, 2017 at 12:25:19PM +1100, NeilBrown wrote:
>> Instead of the cfs workitem library, use workqueues.
>>
>> As lnet wants to provide a cpu mask of allowed cpus, it
>> needs to be a WQ_UNBOUND work queue
On Mon, Jan 08 2018, James Simmons wrote:
>> On Mon, Jan 08, 2018 at 02:28:13PM +1100, NeilBrown wrote:
>> > Hi,
>> > this is a revised version of the patch series I sent under a similar
>> > subject in mid December.
>> > Improvements are:
>&g
On Thu, Mar 08 2018, Dilger, Andreas wrote:
> On Mar 1, 2018, at 16:31, NeilBrown wrote:
>>
>> lustre has a "Pinger" kthread which periodically pings peers
>> to ensure all hosts are functioning.
>>
>> This can more easily be done using a work queu
de_getsecurity() it only wants
a dentry so that it can pass something to __vfs_getxattr(),
and that only wants a dentry so it can pass something to ->get.
Possibly we should rename d_find_alias() to d_find_hashed_alias() so that
people need to make a conscious choice between d_find_hashed_alias() and
d_find_any_alias() ??
Thanks,
NeilBrown
signature.asc
Description: PGP signature
go in through the netdev tree if you
prefer - the last 4 are needed for lustre to work
correctly/optimally.
Thanks,
NeilBrown
---
NeilBrown (6):
rhashtable: improve documentation for rhashtable_walk_peek()
rhashtable: remove outdated comments about grow_decision etc
rhashtable:
the documentation can be correct without
listing too many special cases. I don't think the one user will
be affected by the code change.
Signed-off-by: NeilBrown
---
lib/rhashtable.c | 17 +
1 file changed, 13 insertions(+), 4 deletions(-)
diff --git a/lib/rhashtable.c
grow_decision and shink_decision no longer exist, so remove
the remaining references to them.
Signed-off-by: NeilBrown
---
include/linux/rhashtable.h | 33 ++---
1 file changed, 14 insertions(+), 19 deletions(-)
diff --git a/include/linux/rhashtable.h b/include
able will return every object that was in the
hastable for the duration of the walk, at least once. This can be
used, for example, to selectively delete objects from the table.
Signed-off-by: NeilBrown
---
include/linux/rhashtable.h | 28 ++--
lib/rhashtable.c
ing the
new ->long_chain without locking cannot cause any corruption.
Signed-off-by: NeilBrown
---
include/linux/rhashtable.h | 18 +++---
lib/rhashtable.c | 27 +++
2 files changed, 34 insertions(+), 11 deletions(-)
diff --git a/include/lin
The documentation claims that when rhashtable_walk_start_check()
detects a resize event, it will rewind back to the beginning
of the table. This is not true. We need to set ->slot and
->skip to be zero for it to be true.
Signed-off-by: NeilBrown
---
lib/rhashtable.c |2 ++
1 file c
501 - 600 of 2514 matches
Mail list logo