Re: [RFC PATCH v2 9/9] ksmbd: avoid self oplock breaks for EA opens

Namjae Jeon <[email protected]> Mon, 20 Jul 2026 14:34:57 +0900
Newsgroups org.kernel.vger.linux-cifs,org.kernel.vger.linux-kernel
Message-ID <CAKYAXd8A+A2OqOqgVVOdaTqC+hvu6kjQzgOtD40s55F9cwGJbQ@mail.gmail.com>
On Fri, Jul 17, 2026 at 12:40 PM Ze Tan <[email protected]> wrote:
>
> generic/093 writes to a file after setcap sets security.capability. The
> CIFS client can reopen the file to query or update EAs while the same
> session holds an oplock. ksmbd breaks this oplock and waits for the same
> client, so the write can block.
>
> Skip the oplock break for same-session EA or metadata opens. Keep the
> normal break when another session holds an oplock.
A session can own multiple independent opens. Why is session identity
sufficient to conclude that an EA/metadata-only open may bypass the
existing exclusive or batch oplock break? Oplock state and break
notifications are associated with an individual open, rather
than the session as a whole. Could you point to the SMB specification text ?