[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <Z8CXV4c9GSPXvgLN@google.com>
Date: Thu, 27 Feb 2025 16:48:23 +0000
From: Roman Gushchin <roman.gushchin@...ux.dev>
To: Parav Pandit <parav@...lanox.com>
Cc: Jason Gunthorpe <jgg@...pe.ca>, Leon Romanovsky <leon@...nel.org>,
Maher Sanalla <msanalla@...dia.com>,
"linux-rdma@...r.kernel.org" <linux-rdma@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] RDMA/core: don't expose hw_counters outside of init net
namespace
On Thu, Feb 27, 2025 at 05:22:59AM +0000, Parav Pandit wrote:
>
> > From: Roman Gushchin <roman.gushchin@...ux.dev>
> > Sent: Thursday, February 27, 2025 12:32 AM
> >
> > Commit 5fd8529350f0 ("RDMA/core: fix a NULL-pointer dereference in
> > hw_stat_device_show()") accidentally almost exposed hw counters to non-init
> > net namespaces. It didn't expose them fully, as an attempt to read any of
> > those counters leads to a crash like this one:
> >
> It is not the commit 5fd8529350f0.
> You just want to say cited commit accidentally..
Right, it's a typo, it had to be 467f432a521a ("RDMA/core: Split port
and device counter sysfs attributes").
> > WARN(true, "struct ib_device->groups is too small"); diff --git
> > a/include/rdma/ib_verbs.h b/include/rdma/ib_verbs.h index
> > b59bf30de430..a5761038935d 100644
> > --- a/include/rdma/ib_verbs.h
> > +++ b/include/rdma/ib_verbs.h
> > @@ -2767,6 +2767,7 @@ struct ib_device {
> > * It is a NULL terminated array.
> > */
> > const struct attribute_group *groups[4];
> > + u8 hw_stats_attr_index;
> >
> > u64 uverbs_cmd_mask;
> >
> > --
> > 2.48.1.711.g2feabab25a-goog
>
> With above suggested small commit log correction,
> Reviewed-by: Parav Pandit <parav@...dia.com>
Thank you!
Powered by blists - more mailing lists