Thread (72 messages) 72 messages, 8 authors, 2021-07-07

Re: [PATCH RFC 1/3] fs: introduce helper d_path_fast()

From: Linus Torvalds <torvalds@linux-foundation.org>
Date: 2021-05-08 20:40:27
Also in: linux-fsdevel, linux-s390, lkml

On Sat, May 8, 2021 at 12:13 PM Al Viro [off-list ref] wrote:
Potentiallty delicate question is how to pass bptr/blen to the caller
of that helper...
So I was thinking something like this patch..

THIS IS TOTALLY UNTESTED!

I've basically introduced a "struct prepend_buffer" that acts as that
"end,len" pair and that gets passed around. It builds cleanly for me,
which actually makes me fairly happy that it might even be close
right, because the calling conventions would catch any mistake.

It looks superficially sane to me, but again - untested.

The patch ended up being bigger than I expected, but it's all fairly
straightforward - just munging the calling conventions.

Oh, and I did extract out the core of "prepend_path()" into
"prepend_entries()" just to show how it would work.

              Linus

Attachments

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help