* drivers/hwtracing/stm/core.c:509:8-24: WARNING: stm_fops: .write() has stream semantic; safe to change nonseekable_open -> stream_open. (fwd)
@ 2026-11-01 23:54 Julia Lawall
0 siblings, 0 replies; only message in thread
From: Julia Lawall @ 2026-11-01 23:54 UTC (permalink / raw)
To: Lorenzo Stoakes (Oracle)
Cc: Andrew Morton, Linux Memory Management List, Suren Baghdasaryan,
linux-kernel, oe-kbuild-all
just forwarding. I don't know anything about this issue.
julia
---------- Forwarded message ----------
Date: Mon, 02 Nov 2026 00:48:49 +0100
From: kernel test robot <lkp@intel.com>
To: oe-kbuild@lists.linux.dev
Cc: lkp@intel.com, Julia Lawall <julia.lawall@inria.fr>
Subject: drivers/hwtracing/stm/core.c:509:8-24: WARNING: stm_fops: .write() has
stream semantic; safe to change nonseekable_open -> stream_open.
BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
CC: linux-kernel@vger.kernel.org
TO: "Lorenzo Stoakes (Oracle)" <ljs@kernel.org>
CC: Andrew Morton <akpm@linux-foundation.org>
CC: Linux Memory Management List <linux-mm@kvack.org>
CC: Suren Baghdasaryan <surenb@google.com>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 6628e7d4c6b25c8d18f1345e3a20d21829aae7e4
commit: b0085cb94d2477787f4197a3000e33aabf3d48fc stm: replace deprecated mmap hook with mmap_prepare
date: 7 months ago
:::::: branch date: 2 hours ago
:::::: commit date: 7 months ago
config: mips-randconfig-r2106-20261101 (https://download.01.org/0day-ci/archive/20261102/202611020009.xkUfJUpm-lkp@intel.com/config)
compiler: clang version 24.0.0git (https://github.com/llvm/llvm-project 8f6b51ca8bab1d49006ddaa042bc7e4e7306975d)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Fixes: b0085cb94d24 ("stm: replace deprecated mmap hook with mmap_prepare")
| Reported-by: kernel test robot <lkp@intel.com>
| Reported-by: Julia Lawall <julia.lawall@inria.fr>
| Closes: https://lore.kernel.org/r/202611020009.xkUfJUpm-lkp@intel.com/
cocci warnings: (new ones prefixed by >>)
>> drivers/hwtracing/stm/core.c:509:8-24: WARNING: stm_fops: .write() has stream semantic; safe to change nonseekable_open -> stream_open.
vim +509 drivers/hwtracing/stm/core.c
c7fd62bc69d022 Alexander Shishkin 2018-10-05 484
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 485 static int stm_char_open(struct inode *inode, struct file *file)
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 486 {
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 487 struct stm_file *stmf;
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 488 struct device *dev;
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 489 unsigned int major = imajor(inode);
a0ebf519b8a266 Johan Hovold 2016-11-18 490 int err = -ENOMEM;
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 491
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 492 dev = class_find_device(&stm_class, NULL, &major, major_match);
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 493 if (!dev)
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 494 return -ENODEV;
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 495
bf4afc53b77aea Linus Torvalds 2026-02-21 496 stmf = kzalloc_obj(*stmf);
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 497 if (!stmf)
a0ebf519b8a266 Johan Hovold 2016-11-18 498 goto err_put_device;
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 499
a0ebf519b8a266 Johan Hovold 2016-11-18 500 err = -ENODEV;
cde4ad8368840e Alexander Shishkin 2016-02-15 501 stm_output_init(&stmf->output);
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 502 stmf->stm = to_stm_device(dev);
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 503
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 504 if (!try_module_get(stmf->stm->owner))
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 505 goto err_free;
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 506
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 507 file->private_data = stmf;
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 508
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 @509 return nonseekable_open(inode, file);
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 510
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 511 err_free:
a0ebf519b8a266 Johan Hovold 2016-11-18 512 kfree(stmf);
a0ebf519b8a266 Johan Hovold 2016-11-18 513 err_put_device:
f7c81c7176c72c Alexander Shishkin 2016-02-15 514 /* matches class_find_device() above */
f7c81c7176c72c Alexander Shishkin 2016-02-15 515 put_device(dev);
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 516
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 517 return err;
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 518 }
7bd1d4093c2fa3 Alexander Shishkin 2015-09-22 519
:::::: The code at line 509 was first introduced by commit
:::::: 7bd1d4093c2fa37d1ecab05da3c9d48ea2af2264 stm class: Introduce an abstraction for System Trace Module devices
:::::: TO: Alexander Shishkin <alexander.shishkin@linux.intel.com>
:::::: CC: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2026-11-01 23:54 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-01 23:54 drivers/hwtracing/stm/core.c:509:8-24: WARNING: stm_fops: .write() has stream semantic; safe to change nonseekable_open -> stream_open. (fwd) Julia Lawall
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®